﻿using System;

namespace MvpFramework
{
    /// <summary>
    /// The interface that Presentor Factories must implement
    /// </summary>
    public interface IViewPresenterResolver
    {
        /// <summary>
        /// Returns the <see cref="Type"/> for the View sent
        /// </summary>
        /// <param name="viewInstance"></param>
        /// <returns></returns>
        Type GetPresenterTypeFor(object viewInstance);

        /// <summary>
        /// Returns the View interface for the object sent (will usually
        /// be an aspx page).
        /// </summary>
        /// <param name="page"></param>
        /// <returns></returns>
        Type GetViewTypeFor(object page);
    }
}